<!doctype HTML public "-//W3C//DTD HTML 4.0 Frameset//EN">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="generator" content="Adobe RoboHelp - www.adobe.com">
<title>About calculating totals and summary metrics in documents</title>
<link rel="stylesheet" href="userhelp_ns.css"><script type="text/javascript" language="JavaScript" title="WebHelpSplitCss">
<!--
if (navigator.appName !="Netscape")
{   document.write("<link rel='stylesheet' href='userhelp.css'>");}
//-->
</script>
<style type="text/css">
<!--
table.whs1 { x-cell-content-align:top; margin-left:40px; border-spacing:0px; }
tr.whs2 { x-cell-content-align:top; }
td.whs3 { border-left-width:1px; border-left-color:#000000; border-left-style:Solid; border-top-style:Solid; border-top-color:#000000; border-top-width:1px; border-right-width:1px; border-right-color:#000000; border-right-style:Solid; border-bottom-style:Solid; border-bottom-color:#000000; border-bottom-width:1px; padding-right:10px; padding-left:10px; }
p.whs4 { font-weight:bold; }
td.whs5 { border-top-style:Solid; border-top-color:#000000; border-top-width:1px; border-right-width:1px; border-right-color:#000000; border-right-style:Solid; border-bottom-style:Solid; border-bottom-color:#000000; border-bottom-width:1px; padding-right:10px; padding-left:10px; }
td.whs6 { border-left-width:1px; border-left-color:#000000; border-left-style:Solid; border-right-width:1px; border-right-color:#000000; border-right-style:Solid; border-bottom-style:Solid; border-bottom-color:#000000; border-bottom-width:1px; padding-right:10px; padding-left:10px; }
td.whs7 { border-right-width:1px; border-right-color:#000000; border-right-style:Solid; border-bottom-style:Solid; border-bottom-color:#000000; border-bottom-width:1px; padding-right:10px; padding-left:10px; }
p.whs8 { margin-left:40px; }
ul.whs9 { list-style:disc; }
-->
</style><script type="text/javascript" language="JavaScript" title="WebHelpInlineScript">
<!--
function reDo() {
  if (innerWidth != origWidth || innerHeight != origHeight)
     location.reload();
}
if ((parseInt(navigator.appVersion) == 4) && (navigator.appName == "Netscape")) {
	origWidth = innerWidth;
	origHeight = innerHeight;
	onresize = reDo;
}
onerror = null; 
//-->
</script>
<style type="text/css">
<!--
div.WebHelpPopupMenu { position:absolute; left:0px; top:0px; z-index:4; visibility:hidden; }
-->
</style><script type="text/javascript" language="javascript1.2" src="whmsg.js"></script>
<script type="text/javascript" language="javascript" src="whver.js"></script>
<script type="text/javascript" language="javascript1.2" src="whproxy.js"></script>
<script type="text/javascript" language="javascript1.2" src="whutils.js"></script>
<script type="text/javascript" language="javascript1.2" src="whlang.js"></script>
<script type="text/javascript" language="javascript1.2" src="whtopic.js"></script>
</head>
<body><script type="text/javascript" language="javascript1.2">
<!--
if (window.gbWhTopic)
{
	if (window.addTocInfo)
	{
	addTocInfo("Creating and modifying documents and dashboards\nCreating and formatting a document\nWorking with metrics and totals in documents\nCalculating totals and summary metrics in documents\nAbout calculating totals and summary metrics in documents");
addButton("show",BTN_TEXT,"Show","","","","",0,0,"","","");

	}
	if (window.writeBtnStyle)
		writeBtnStyle();

	if (window.writeIntopicBar)
		writeIntopicBar(1);

	if(1)
	{
	
	}

	if (window.setRelStartPage)
	{
	setRelStartPage("MicroStrategy_Web_Help.htm");

		autoSync(1);
		sendSyncInfo();
		sendAveInfoOut();
	}
}
else
	if (window.gbIE4)
		document.location.reload();

//-->
</script>
<h1>About calculating totals and summary metrics in documents </h1>
<p>A metric is calculated differently depending on its location in the 
 document. For example, a metric placed in a text field on a group header 
 or footer section calculates a subtotal for that grouping level. The same 
 metric in a text field on the Document Header or Footer provides a grand 
 total for the document. The following table describes how metrics are 
 calculated in various locations within a document. The information below 
 the table discusses how metrics are calculated depending on which section 
 of the document they are placed in.</p>
<p>&nbsp;</p>
<table x-use-null-cells cellspacing="0" class="whs1">
<script language='JavaScript'><!--
if ((navigator.appName == "Netscape") && (parseInt(navigator.appVersion) == 4)) document.write("</table><table x-use-null-cells cellspacing='0' border='1' bordercolor='black' bordercolorlight='black' bordercolordark='black'>");
//--></script>
<col>
<col>


<tr valign="top" class="whs2">
<td class="whs3">
<p class="whs4">Metric Location</td>
<td class="whs5">
<p class="whs4">Metric Calculation</td></tr>

<tr valign="top" class="whs2">
<td class="whs6">
<p>In a text field in Detail section</td>
<td class="whs7">
<p>At the level returned by the dataset report</td></tr>

<tr valign="top" class="whs2">
<td class="whs6">
<p>In a text field in a group header/footer </td>
<td class="whs7">
<p>Totaled at the level of the group</td></tr>

<tr valign="top" class="whs2">
<td class="whs6">
<p>In a text field in the Document Header/Footer or Page Header/Footer 
 </td>
<td class="whs7">
<p>Totaled across entire dataset</td></tr>

<tr valign="top" class="whs2">
<td class="whs6">
<p>In a Grid/Graph control in a group header/footer </td>
<td class="whs7">
<p>At the level defined by the attributes, consolidations, or custom groups 
 on the Grid/Graph, and at the level of the grouping section</td></tr>

<tr valign="top" class="whs2">
<td class="whs6">
<p>In a Grid/Graph control in the Document Header/Footer or Page Header/Footer 
 </td>
<td class="whs7">
<p>At the level defined by the attributes, consolidations, or custom groups 
 on the Grid/Graph</td></tr>
<script language='JavaScript'><!--
if ((navigator.appName == "Netscape") && (parseInt(navigator.appVersion) == 4)) document.write("</table></table><table>");
//--></script>
</table>
<p class="whs8"><span style="font-weight: bold;"><B>Note</B></span>: 
 If a Grid/Graph does not contain anything other than the metric, the metric 
 returns the same value as if it were placed in a text field in that section. 
 This rule applies regardless of what section the Grid/Graph is located 
 in. For more information on Grids/Graphs, see 
<a href="Using_GG_in_documents.htm">Using 
 Grid/Graphs in documents</a>.</p>
<p>The metric calculation for totals is determined by the default subtotal 
 specified in the metric definition. To specify the function used to calculate 
 a subtotal, create a summary metric. For steps, see 
<a HREF="Creating_summary_metrics_documents.htm">Working 
 with summary metrics in documents</a>.</p>
<p>The <span style="font-style: italic;"><I>MicroStrategy Report Services 
 Document Creation Guide</I></span> contains detailed examples of metric calculation 
 in documents.</p>
<p class="whs4">Related topics</p>
<ul type="disc" class="whs9">
	
<li class=p><p>
<a HREF="Calculating_totals_in_documents.htm">Calculating 
 totals in documents</a></p></li>
	
<li class=p><p>
<a HREF="Creating_summary_metrics_documents.htm">Working 
 with summary metrics in documents</a></p></li>
	
<li class=p><p>
<a HREF="Add_data_fields_to_document.htm">Adding data 
 fields to a document</a></p></li>
</ul>
<script type="text/javascript" language="javascript1.2">
<!--
highlightSearch();
if (window.writeIntopicBar)
	writeIntopicBar(0);
if(0)
{

}
//-->
</script>
</body>
</html>
